@extends('home.layout.index')

@section('content')

<div class="i_bg">
	<div class="postion">
	
    	<span class="fl">全部 > {{$pname->name}} >{{$details->name}} </span>
    
    </div>
    
    <div class="content mar_20">

        <div class="l_history">
            <div class="his_t">
                <span class="fl">最新发布商品</span>
            </div>
            <ul>

            @foreach($newest as $k=>$v)
                <li>
                    <div class="img"><a href="#"><img src="{{asset($v->pic)}}" width="185" height="162" /></a></div>
                    <div class="name"><a href="#">{{$v->title}}</a></div>
                    <div class="price">
                        <font>￥<span>{{$v->price}}</span></font>
                    </div>
                </li>
            @endforeach
            </ul>
        </div>

        <div class="l_list">
        	<div class="list_t">
            	<span class="fl list_or">
                	<a href="#" class="now">默认</a>
                    <a href="#">
                    	<span class="fl">价格</span>                        
                        <span class="i_up">价格从低到高显示</span>
                        <span class="i_down">价格从高到低显示</span>     
                    </a>
                </span>
                <span class="fr">共发现{{$count}}件</span>
            </div>
               
			@foreach($data as $k=>$v)
            <div class="" style="margin:0px auto;">
				
                <ul class="cate_list" style="margin_top:0px">
                	<li>
                    	<div class="img"><a href="#"><img src="{{asset($v['pic'])}}" width="210" height="185" /></a></div>
                        <div class="price">
                            <font>￥<span>{{$v['price']}}</span></font>
                        </div>
                        <div class="name"><a href="#">{{$v['title']}}</a></div>
                        <div class="carbg">
                        	<a href="{{url('/click/'.$v['id'])}}" class="ss" style="width:100px">收藏({{$v['count']}})</a>
                            <a href="{{url('/goods/'.$v['id'])}}" class="j_car" style="width:100px">查看</a>
                        </div>
                    </li>
                </ul>
            </div>
            @endforeach
            
        </div>
        <div class="pages" style="width:100%;float:right;">

              {!! $data->appends($request)->render()!!}

        </div>
    </div>
</div>


@endsection